#!/usr/bin/python
import sys
import os
import tempfile

os.chdir(tempfile.gettempdir())

file = sys.argv[1]

f = os.popen3("msgfmt -c "+file)
line = f[2].read()
if line != "":
    print line
    sys.exit(1)